{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {
    "slideshow": {
     "slide_type": "skip"
    }
   },
   "source": [
    "# 离婚财产分割"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "slideshow": {
     "slide_type": "skip"
    }
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "0.10189090085999997\n",
      "sum 0.13222690810319998\n",
      "0.07528884299999998\n",
      "sum 0.1412615692632\n",
      "0.04945079999999999\n",
      "sum 0.1471956652632\n",
      "0.02436\n",
      "sum 0.15011886526319998\n"
     ]
    }
   ],
   "source": [
    "估值=300 #万元\n",
    "#男方， 获得 \n",
    "男方比例=0.12\n",
    "分期年=5\n",
    "年利率=1.015\n",
    "sum=0\n",
    "for 已过年 in range(1,分期年):\n",
    "   \n",
    "    每年付本金=男方比例/分期年\n",
    "    \n",
    "    未付=每年付本金*(分期年-已过年)\n",
    "   \n",
    "    利息=未付*pow(年利率,分期年-已过年)\n",
    "    print(利息)\n",
    "    sum+=利息\n",
    "    print( \"sum\",sum*男方比例+男方比例)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "slideshow": {
     "slide_type": "slide"
    }
   },
   "source": [
    "# 贷款 装修"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "slideshow": {
     "slide_type": "notes"
    }
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import matplotlib.pyplot as plt \n",
    "plt.rcParams['font.sans-serif']=['SimHei'] #指定默认字体 SimHei为黑体"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "slideshow": {
     "slide_type": "notes"
    }
   },
   "outputs": [],
   "source": [
    "#%home\n",
    "T=48\n",
    "x=np.arange(0,T,1) #月每月计算\n",
    "贷款本金=50000\n",
    "利率=0.007\n",
    "贷款总额=贷款本金*利率\n",
    "房租=4400\n",
    "出租=3500\n",
    "T贷款起=0;T贷款止=6;ld=T贷款=-T贷款起+T贷款止\n",
    "T租房起=0;T租房止=T;lz=T租房=-T租房起+T租房止\n",
    "T出租起=3;T出租止=T;lc=T出租=-T出租起+T出租止\n",
    "\n",
    "T贷款=np.pad(np.arange(ld),(T贷款起,T-ld-T贷款起),\"maximum\")  #月\n",
    "T租房=np.pad(np.arange(lz),(T租房起,T-lz-T租房起),\"constant\")\n",
    "T出租=np.pad(np.arange(lc),(T出租起,T-lc-T出租起),\"constant\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "slideshow": {
     "slide_type": "notes"
    }
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "[<matplotlib.lines.Line2D at 0x29c4086d0b8>]"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAZgAAAEHCAYAAACTC1DDAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAIABJREFUeJzt3WlwXNd55vH/i30jlgYa3EQSABfAsqiFAsFFG6ixnUhylnFlHNfEjmuSlDyplFOpLDN2xVnGZSceT5IvqdFkNFGcVCVORs5iR6bjKBoRFCVTokhJ1gqQFHeKFBoESQAksfY7H+5li6ZEskng9kV3P78qFBunm+j33gLw4Jxzz7nm7oiIiMy1krgLEBGRwqSAERGRSChgREQkEgoYERGJhAJGREQioYAREZFIKGBERCQSChgREYmEAkZERCJRFncBcWppafG2tra4yxARySt79uwZcvfktV5X1AHT1tbG7t274y5DRCSvmNnhbF6nITIREYmEAkZERCKhgBERkUgoYEREJBIKGBERiYQCRkREIlFwAWNmj5nZTjP7Uty1iIgUs4IKGDP7BFDq7puADjNbHcX7/N8Xj/DlJ96M4kuLiBSMggoYoBd4PHz8JHD35S8ws4fNbLeZ7U6lUjf0JvsHx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]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "#print(td,tz,tc)\n",
    "y=( -(贷款本金/ld)*(1+利率)*T贷款-房租*T租房+出租*T出租)\n",
    "\n",
    "plt.xlabel(\"月份\")\n",
    "plt.ylabel(\"收益\")\n",
    "plt.plot(x,y)\n",
    "\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "slideshow": {
     "slide_type": "subslide"
    }
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[0. 0. 0. 0. 0. 5. 6. 7. 8. 9.]\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "[<matplotlib.lines.Line2D at 0x29c408fa908>]"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAWwAAAD6CAYAAACF131TAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAF0FJREFUeJzt3Xl8VOWhxvHnDSQsAUIgCYsQtoABAREiFAWrgLtWUbzaWm1dSu219Xb5qLjVWrWure21Fy1a/egVW68srqgMCriBCloSmBD2nUxCQhZIAknmvX+QlEUgA8zkzDnn9/1rIJPkccSH48k5zxhrrQAA8S/B6QAAgMhQ2ADgEhQ2ALgEhQ0ALkFhA4BLUNgA4BIUNgC4BIUNAC5BYQOAS7SM5hdLS0uzvXv3juaXBADPW7p06Q5rbXpTz4tqYffu3VtLliyJ5pcEAM8zxmyM5HmcEgEAl6CwAcAlKGwAcAkKGwBcgsIGAJegsAHAJShsAHAJChsATkBtfVhTF6zRss1lMf9eUb1xBgD8ZPnWct05M1crtlXolu/W6dSeHWP6/ShsADhGNbX1evqj1Xp24Tqltk3SM9cO14VDusX8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MAOKJIjrDfkPSJMaa7pAslfSe2kQAAh9PkEba1tkL7fvC4WNI51tryWIcCAHxbJEfYstbu1P4rRQAADuBORwBwCQobAFyCwgYAl6CwAcAljLXHda/L4b+YMcWSNh7np6dJ2hG1MO7H63EwXo/9eC0O5oXXo5e1Nr2pJ0W1sE+EMWaJtTbH6RzxgtfjYLwe+/FaHMxPrwenRADAJShsAHCJeCrsaU4HiDO8Hgfj9diP1+Jgvnk94uYcNgDg6OLpCBsAcBQUdpwxxqQYY94zxsw1xsw2xiQ5nclpxpguxphvnM4RL4wxU40xlzqdw2nGmFRjzBxjzBJjzN+cztMc4qKweZPfg1wr6U/W2vMkFUq6wOE88eBJ7X8TDV8zxoyV1NVa+7bTWeLAdZKmN1zS194Y4/lL+xwvbN7k92DW2qnW2kDDL9MlFTmZx2nGmHGSdmvfX16+ZoxJlPScpA3GmMuczhMHSiQNNsZ0lNRT0maH88Sc44Wtw7/Jr+8ZY0ZLSrXWLnY6i1MaTgfdJ2mK01nixPWSgpIelzTSGPMLh/M47VNJvSTdJilf+95z1tPiobAPfZPfLg5miQvGmE6SnpZ0o9NZHDZF0lRrbZnTQeLEaZKmWWsLJb0i6RyH8zjtfkm3WGt/L2mlpBsczhNz8VDYR32TX79pOKp8XdJd1trj3WXxigmSbjXGLJA0zBjzvMN5nLZGUt+Gxzk6/t0er0iVNMQY00LSKEmev0bZ8euwjTHXS8qw1j5pjHlAUoG19lVHQznIGPMzSX+QtKzht56x1r7mYKS4YIxZYK092+kcTjLGtJf0gvb9X2iipEnW2q1H/yzvMsaMlPSi9p0WWSRporV2l7OpYiseCruDpE8kfaiGN/nlfSMB4NscL2xp3/WUks6V9HHD+TkAwCHiorABAE3z9Q/4AMBNKGwAcAkKGwBcgsIGAJegsAHAJf4fgMTtAg7KR0AAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "x=np.arange(0,10,1) #月每月计算\n",
    "y=x \n",
    "z=x*np.append(np.zeros(5),np.ones(5))\n",
    "print(z)\n",
    "plt.plot(x,z)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 127,
   "metadata": {
    "slideshow": {
     "slide_type": "slide"
    }
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([0., 0., 0., 1., 1., 1., 1., 1., 0., 0., 0., 0., 0., 0., 0.])"
      ]
     },
     "execution_count": 127,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "aa=np.ones(5)\n",
    "bb=np.pad(aa,(0,4),mode=\"constant\")\n",
    "np.pad(bb,(3,3),\"constant\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "slideshow": {
     "slide_type": "slide"
    }
   },
   "source": [
    "# markdown\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "celltoolbar": "幻灯片",
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.1"
  },
  "toc": {
   "base_numbering": 1,
   "nav_menu": {},
   "number_sections": true,
   "sideBar": true,
   "skip_h1_title": false,
   "title_cell": "Table of Contents",
   "title_sidebar": "Contents",
   "toc_cell": false,
   "toc_position": {
    "height": "calc(100% - 180px)",
    "left": "10px",
    "top": "150px",
    "width": "165px"
   },
   "toc_section_display": true,
   "toc_window_display": true
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
